Tryit Editor v2.3

Edit This Code:
<!DOCTYPE html> <html> <head> <style> table, th, td { border: 1px solid black; } </style> </head> <body> <p>Click the button to change the caption-side property of the CAPTION element.</p> <button onclick="myFunction()">Try it</button> <table> <caption id="myCap">Table 1.1 Customers</caption> <tr> <th>Company</th> <th>Contact</th> <th>Country</th> </tr> <tr> <td>Alfreds Futterkiste</td> <td>Maria Anders</td> <td>Germany</td> </tr> <tr> <td>Berglunds snabbköp</td> <td>Christina Berglund</td> <td>Sweden</td> </tr> <tr> <td>Centro comercial Moctezuma</td> <td>Francisco Chang</td> <td>Mexico</td> </tr> </table> <script> function myFunction() { document.getElementById("myCap").style.captionSide = "bottom"; } </script> </body> <!-- Mirrored from www.w3schools.com/cssref/tryit.asp?filename=trycss_js_caption-side by HTTrack Website Copier/3.x [XR&CO'2014], Fri, 23 Jan 2015 07:51:24 GMT --> </html>
Result:
Try it Yourself - © w3schools.com